package headfirst.combined.djview;
import java.awt.Graphics;

import javax.swing.ImageIcon;
import javax.swing.JPanel;

//import Forma3.TransparentPanel;

public class Fondo extends JPanel {
	private int ancho, alto;
	public Fondo (){
		this.setSize(100,100);
	}
	
	public void paintComponent(Graphics g){
		alto = 100;
		ancho = 100;
		
		ImageIcon imagenFondo = new ImageIcon(getClass().getResource("fondo.jpg"));
		g.drawImage(imagenFondo.getImage(), 0, 0, ancho, alto, null);
		
		setOpaque(false);
		
		super.paintComponent(g);
	}
}
